home *** CD-ROM | disk | FTP | other *** search
- /*
- File: DwPtInit.cpp
-
- Contains: Init routines for the EditorSetup part library
-
- Owned by: Eric House
-
- Copyright: © 1994 - 1996 by Apple Computer, Inc., all rights reserved.
-
- Change History (most recent first):
-
- <2> 5/24/96 jpa 1246074: Call Mwerks init/terminate fns for
- native exceptions.
- <12> 10/11/95 JBS 1290487 fix to allow editor swapping
- <11> 9/29/95 TJ Removed the SOMInit Routine.
- <10> 9/4/95 TJ Added Includes to Compile with out
- PC-Headers.
- <9> 8/11/95 jpa Call InitODMemory [1276412]
- <8> 1/25/95 jpa Renamed SOM class to Container [1213318]
- <7> 1/12/95 jpa Don't use obsolete Toolbox names [1211211].
- Don't export CFM init [1210936]
- <6> 9/29/94 RA 1189812: Mods for 68K build.
- <5> 9/8/94 NP Removed warning.
- <4> 8/17/94 CG #1181487: Call DrawPartNewClass to
- instantiate DrawPart by name using SOM.
- <3> 7/12/94 jpa Call InitLibraryResources.
- <2> 7/6/94 eeh just testing....
- <1> 7/6/94 eeh first checked in
-
- To Do:
- In Progress:
-
- */
-
-
- /* #include <somcls.xh> */
- #include <som.xh>
- #include <somobj.xh>
-
- #ifndef _ODMEMORY_
- #include <ODMemory.h>
- #endif
-
- #ifndef SOM_AppleTest_Container_xih
- #include "DrawPart.xih"
- #endif
-
- #ifndef _USERSRCM_
- #include <UseRsrcM.h>
- #endif
-
-
- #ifdef __MWERKS__
- extern "C" {
- void __initialize(); // From Metrowerks runtime library, Startup.c
- void __terminate();
- }
- #endif
-
-
- extern "C" pascal OSErr DrawPartCFMInit (CFragInitBlockPtr initBlkPtr);
- extern "C" pascal void DrawPartCFMTerminate( );
-
- pascal OSErr DrawPartCFMInit (CFragInitBlockPtr initBlkPtr)
- {
- #ifdef __MWERKS__
- __initialize(); // Initialize static data and construct any global objects
- #endif
- somNewClass(AppleTest_Container);
- InitODMemory();
- return InitLibraryResources(initBlkPtr);
- }
-
- pascal void DrawPartCFMTerminate( )
- {
- CloseLibraryResources();
- #ifdef __MWERKS__
- __terminate(); // Destruct static objects & clean up exception tables
- #endif
- }
-